Applications and high performance networks to support new usage models and services such as voice, video, transactions, and private data, present new challenges in the area of security. The need to protect data in storage or in transit for confidentiality and integrity is important, but supporting high speed cryptographic operations and storage required to maintain secured access to protected code and/or data adds to complexity and ultimately to expense.
One technique for creating and maintaining a secured, protected, or isolated partition or environment is known as establishing an enclave. An enclave is a set of information and processing capabilities that are protected as a group. The information and processing capabilities may include networks, hosts, or applications. When data and/or instructions for an enclave are loaded from external memory, they are decrypted, authenticated and then stored or cached in a protected memory. Similarly when data and/or instructions for an enclave are evicted from the protected memory, they are encrypted before being stored back to external memory. Secure enclave data is allocated to a particular process and associated with a unique enclave identifier for that process, such that access to the secure enclave data is restricted to an authorized process. Not even the operating system is permitted to access decrypted enclave data associated with an enclave identifier of a different process.
Therefore, when a process that has been allocated a secure enclave needs to be migrated to another machine, platform or server, the operating system cannot access the decrypted enclave data associated with the parent process. Accordingly, the operating system may not be able to duplicate the state of a process for a migrated process while the secure enclave allocated to the running process is still active. Furthermore, the secure enclave is bound to a platform by its keys, so in order to migrate to another platform, the platform needs to be virtualized and the secure enclave needs to be bound instead to a virtual machine or container running on the platform. Then, at least when the secure enclave is shutdown, the process and/or virtual machine could be securely migrated to another physical platform.
In order for the operating system to duplicate the secure enclave state allocated to a process for migrating that process to another physical platform, memory pages may typically be paged out of, and invalidated from the protected memory. When the operating system is performing paging in (i.e. loading) and/or paging out (i.e. evicting and writing back) of memory pages for a secure enclave, cryptographic operations must be performed on entire pages, which may be typically of 4 KB in size. Consequently, page copying operations for a secure enclave may require many tens of thousands of processing cycles. If a paging process is interrupted, it may need to be re-executed, but if servicing of interrupts were not permitted until paging operations for the secure enclave had completed, then the delayed servicing of interrupts may cause unacceptable glitches in some services such as voice, video and real-time transactions. It will be appreciated that to be securely migrated to another physical platform, any copying of memory data pages and/or executable pages would need to be securely managed, and especially if the copying of such data pages and/or executable pages occurred during a live migration of the virtual machine or container to another platform, a version control of each memory data page and/or executable page for the secure enclave would also need to be securely managed.
Therefore duplicating pages of data and state for a secure enclave to migrate a process to another machine, platform or server presents a set of unique security, user-experience and performance challenges. To date, solutions that address these challenges, potential performance limiting issues, and real-time complexities have not been adequately explored.